package com.huc.design.behavior.observer.casedemo;

/**
 * @author huc
 * @version 1.0
 * @note
 * @date 2021/10/8 13:57
 */
public class BellEventTest {
    public static void main(String[] args) {
        BellEventSource source = new BellEventSource();
        source.addPersonListener(new TeachEventListener());
        source.addPersonListener(new StudentEventListener());
        source.ring(true);
        System.out.println("-------一小时后----------");
        source.ring(false);
    }
}
